package com.hjxr.quota.define.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hjxr.quota.define.domain.QuotaDimRelationDetail;
import com.hjxr.quota.define.domain.vo.DimensionRootVo;
import com.hjxr.quota.datasource.domain.QuotaDimension;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface QuotaDimRelationDetailMapper extends BaseMapper<QuotaDimRelationDetail> {

    List<DimensionRootVo> selectDimensionNameByQuotaId(@Param("quotaId") Integer quotaId);

    List<DimensionRootVo> selectRootNode(@Param("upperIds") List<Integer> upperIds);

    List<DimensionRootVo> selectBeMixed(@Param("quotaId") Integer quotaId,@Param("quotaIds") List<Integer> quotaIds);

    List<Integer> selectBeMixedReturnId(@Param("quotaId") Integer quotaId,@Param("quotaIds") List<Integer> quotaIds);

    List<QuotaDimension> selectRootNodeTree(@Param("dimIds")List<Integer> dimIds);
}
